package com.lwq.designpattern.structuralPatterns.proxyPattern.dynamicJDKProxy;

/**
 * @ClassName JDK动态代理
 * @Description
 * @Author liwq
 * @Date 2021/4/29 16:15
 * @Version 1.0
 */
public class dynamicJDKProxyDemo {
    public static void main(String[] args) {
        IUser iUser = new IUserImpl();
        System.out.println(iUser.getClass());

        IUser proxy = (IUser) new ProxyFactory(iUser).getProxyInstance();
        System.out.println(proxy.getClass());

        proxy.save();
    }
}
